package config

type RedisConfig struct {
	Host        string `mapstructure:"host"`
	Prot        int    `mapstructure:"port"`
	Db          int    `mapstructure:"db"`
	Pwd         int    `mapstructure:"pwd"`
	PoolSize    int    `mapstructure:"poolSize"`
	MinIdleConn int    `mapstructure:"minIdleConn"`
}

type MysqlYZConfig struct {
	DB_Host     string `mapstructure:"db_host"`
	DB_PORT     int    `mapstructure:"db_port"`
	DB_DATABASE string `mapstructure:"db_database"`
	DB_USERNAME string `mapstructure:"db_username"`
	DB_PASSWORD string `mapstructure:"db_password"`
	DB_DEBUG    bool   `mapstructure:"db_debug"`
}

type TengXunConfig struct {
	Secret_Id  string `mapstructure:"secret_id"`
	Secret_Key string `mapstructure:"secret_key"`
}

type QiNiuYzConfig struct {
	Domain     string `mapstructure:"domain"`
	Access_key string `mapstructure:"access_key"`
	Secret_Key string `mapstructure:"secret_key"`
}

type ServerConfig struct {
	SName       string        `mapstructure:"name"`
	RedisInfo   RedisConfig   `mapstructure:"redis"`
	MysqlYZInfo MysqlYZConfig `mapstructure:"mysql-yz"`
	QiNiuYzInfo QiNiuYzConfig `mapstructure:"qiniu-yz"`
	TengXunInfo TengXunConfig `mapstructure:"teng-xun"`
}
